<nz-layout style="height: 100%">
  <nz-header class="header">
    <div class="logo">
      <img [src]="os.oem.logo" alt="logo">
    </div>
    <div class="title">
      {{os.oem.title}}
    </div>
    <div class="fill">
    </div>
    <div class="user" nzTrigger="click" nz-dropdown [nzDropdownMenu]="menu">
      <!-- <a nz-button nzSize="small" routerLink="/desktop" style="margin-right: 5px;">
        <span nz-icon nzType="swap" nzTheme="outline"></span>
        桌面模式
      </a> -->
      <img class="avatar" src="/assets/user.svg" alt="logo">
      {{userInfo.name}}
    </div>
    <nz-dropdown-menu #menu="nzDropdownMenu">
      <ul nz-menu>
        <li nz-menu-item routerLink="/admin/user/me">个人中心</li>
        <li nz-menu-item routerLink="/admin/user/password">修改密码</li>
        <li nz-menu-item routerLink="/desktop">桌面模式</li>
        <li nz-menu-item (click)="logout()">退出</li>
      </ul>
    </nz-dropdown-menu>
  </nz-header>
  <nz-layout>
    <nz-sider nzBreakpoint="sm" style="overflow-y: auto">
      <ul nz-menu nzTheme="dark" nzMode="inline">
        <li nz-submenu [nzIcon]="app.nzIcon" [nzTitle]="app.name" *ngFor="let app of _as.apps" [nzOpen]="app.open">
          <ul>
            <li nz-menu-item nzMatchRouter nzMatchRouterExact *ngFor="let entry of app.entries">
              <a [routerLink]="['/admin'+entry.path]">
                <span>{{entry.name}}</span>
              </a>
            </li>
          </ul>
        </li>
      </ul>
    </nz-sider>
    <nz-content style="overflow-y: auto">
      <router-outlet></router-outlet>
    </nz-content>
  </nz-layout>

</nz-layout>